package com.yunhe.policyfulfillment.policyful.service;

import com.yunhe.common.exception.ArgumentErrorException;
import com.yunhe.common.model.mybatis.PageResult;
import com.yunhe.policyfulfillment.policyful.domain.Banner;
import com.yunhe.policyfulfillment.policyful.model.BannerQueryCondition;

import java.util.Date;
import java.util.List;

/**
 * @ClassName: BannerService
 * @Description:
 * @author: GongDaCheng
 * @Date: 15:43 2021/7/21
 */
public interface BannerService {

    /**
     * @Description 新增发布Banner
     * @Param Long userId, Banner banner
     * @Return Banner
     * @Date 2021/7/21 15:47
     */
    int create(Banner banner);

    /**
     * @Description 根据id获取Banner
     * @Param Long id
     * @Return Banner
     * @Date 2021/7/22 11:09
     */
    Banner getById(Long id);

    /**
     * @Description 修改Banner
     * @Param Banner banner
     * @Return int
     * @Date 2021/7/22 14:06
     */
    int update(Banner banner);


    /**
     * @Description 获取所有Banner
     * @Param bannerQueryCondition
     * @Return List<Banner>
     * @Date 2021/7/22 9:21
     */
    PageResult getByCondition(BannerQueryCondition bannerQueryCondition) throws ArgumentErrorException;

    /**
     * @Description Banner上线下线操作
     * @Param String ids
     * @Return 
     * @Date 2021/7/22 15:41
     */
    void onlineOffline(String ids, String targetStatus);

    /**
     * @Description Banner置顶操作
     * @Param Long id
     * @Return
     * @Date 2021/7/22 16:21
     */
    void top(Long id);

    /**
     * @Description 根据id删除Banner
     * @Param Long id
     * @Return int
     * @Date 2021/7/22 16:56
     */
    int deleteById(Long id);

    /**
     * @Description 前台获取Banner
     * @Param
     * @Return List<Banner>
     * @Date 2021/7/26 11:04
     */
    List<Banner> getBanner();

    /**
     * @Description 定时发布Banner
     * @Param
     * @Return
     * @Date 2021/8/2 16:52
     */
    void publishTimedBanner();
}
